package com.example.demo.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.demo.entity.Demand;
import com.example.demo.entity.PlatformAward;
import com.example.demo.mapper.PlatformAwardMapper;
import com.example.demo.mapper.PlatformMapper;
import com.example.demo.service.PlatformAwardService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * @author lzc
 * @date 2021/11/10 15 44
 * discription
 */
@Slf4j
@Service
public class PlatformAwardServiceImpl extends ServiceImpl<PlatformAwardMapper, PlatformAward> implements PlatformAwardService {

    @Override
    public List<PlatformAward> findByPlatformId(Integer platformId) {
        QueryWrapper<PlatformAward> queryWrapper = new QueryWrapper<PlatformAward>().
                eq(platformId != null, "platform_id", platformId);

        return super.list(queryWrapper);
    }
}
